<link rel="stylesheet" type="text/css" href="<?= base_url() ?>file/js/easyui/themes/gray/easyui.css">
<link rel="stylesheet" type="text/css" href="<?= base_url() ?>file/js/easyui/themes/icon.css">

<script type="text/javascript" src="<?= base_url() ?>file/js/jquery-1.4.js"></script>
<!--<script type="text/javascript" src="<?= base_url() ?>file/js/add-item.js"></script>-->
	

		
<form id="form" action="<?=base_url() ?>returns/save" method="post">
	<div class="panel-wrap" style="height: auto">
		<div class="panel-header-div">Cluster Information</div>
		<div class="panel-body-div">
		
			<div class="left-panel-body">
				<?php foreach($cluster as $item):?>
					<h2><?php echo $item->distributor_name?></h2>
					<p><?php echo $item->distributor_address?></p>
				<?php endforeach?>
			</div>
			<div class="right-panel-body">
				<table class="table-right-panel" width="100%" border="solid black 1px">
					<tr align="center" class="tr-colour">
						<th width="50%" align="center">Date</th>
						<th align="center">Return No</th>
					</tr>
					
					
					<tr align="center" class="gray">
						<td class="readonly" width="50%" align="center">
							<input type="text" name="return_date"  id="date" readonly="true" value="<?php echo $return-date?>"/>	
						</td>
						
						<td class="readonly" width="50%" align="center">
							<input type="text" name="return_no"  id="return_no" disabled="true" value="<?php echo returns-no?>"/>
						</td>
						
					</tr>
				</table>
			</div>
			
		</div>
	</div>


	<div class="panel-wrap" style="height: auto">
		<div class="panel-header-div">Return Information</div>
		
		<div class="panel-body-div">
			<div class="child-panel-body">
				<div class="left-panel-body">
				
					<table class="table-right-panel" width="60%" border="solid black 1px">
						<tr align="center" class="tr-colour2">
							<th align="center">Sales Name</th>
							<th width="20%" align="center">Sales ID</th>
						</tr>
						
						
						<tr align="center" class="gray">
							<td>
								<input type="text" name="sales_id"  id="sales_id" readonly="true" value="<?php echo $sales-name?>"/>
							</td>
							<td class="readonly" align="center">
								<input type="text" name="sales_name" id="sales-name" size="40" disabled="true" value="<?php echo $sales-id?>"/>
							</td>
							
							
						</tr>
					</table>
				</div>
			</div>
			<div class="child-panel-body">
				<div class="left-panel-body">
				
					<table class="table-right-panel" width="60%" border="solid black 1px">
						<tr align="center" class="tr-colour2">
							<th align="center">Outlet Name</th>
							<th width="20%" align="center">Outlet ID</th>
						</tr>
						
						
						<tr align="center" class="gray">
							<td>
								<input type="text" name="outlet_id"  id="outlet_id" readonly="true" value="<?php echo $outlet-name?>"/>
							</td>
							<td class="readonly" align="center">
								<input type="text" name="outlet_name" id="outlet-name" size="40" disabled="true" value="<?php echo $outlet-id?>"/>
							</td>
							
							
						</tr>
					</table>
				</div>
			
			</div>
			<br><br>
					
			<div class="child-panel-body">
				
					<table class="table-right-panel" id="table-updateable" width="92%" style="margin-left: 19px;">
						<tr align="center" class="tr-colour3" id="tr_select_all">
							<th><input type="checkbox" id="select_all"/></th>
							<th>ICCID</th>
							<th>Buying Date</th>
							<th>Description</th>
							<th>Price (Rp.)</th>							
						</tr>
						<?php foreach($items as $item):?>
							<tr>
								<td class="readonly"><input type="checkbox"/></td>
								<td><input type="text" size="15" value="<?php echo $item->iccid?>"/></td>
								<td class="readonly"><input type="text" readonly="true" value="<?php echo $item->created_on?>"/></td>
								<td><input type="text" readonly="true" value="<?php echo $item->item_name?>"/></td>
								<td class="readonly"><input type="text" readonly="true" value="<?php echo $item->price?>"/></td>
							</tr>
							
						<?php endforeach?>
						
					</table>
			</div>
		
			<div class="child-panel-body-2">
				<table class="table-right-panel" width="92%" style="margin-left: 19px; border: none; ">
					<tr style="height: 15px;">
						<td style="text-align: left; font-weight: bold; font-size: 1.3em;">Remark:</td>
						<td width="94%" style="border-bottom: solid #000 1px;">
							<textarea name="remark" rows="6" cols="130" value="<?php echo $remark?>"></textarea>
						</td>
						
					</tr>
				</table>
			</div>
		
			
		</div>
	</div>
</form>